package project.controllers;

import entities.Garage;
import entities.IGarage;
import entities.IMaster;
import entities.IOrder;
import entities.Master;
import entities.Order;


public class CreatorObject {
	
	private static Controller controller=Controller.getInstance();
	

	public static IGarage addGarage() {
		IGarage garage = new Garage(controller.getNumberGarage());
		return garage;
	}

	public static IMaster addMaster() {
		IMaster master = new Master(controller.getMasterName());
		return master;
	}

	public static IOrder addOrder() {
		IOrder order = new Order();
		
		order.setNumberOrder(controller.getNumberOrder());
		order.setFillingDate(controller.getFillingDate());
		order.setDeadlineDate(controller.getDeadlineDate());
		order.setBeginingDate(controller.getBeginingDate());
		order.setPrice(controller.getPrice());
		
		return order;
	}
}
